import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User:何人亮
 * Date:2024-05-04
 * 16:32
 */
public class Test {
    public static void main(String[] args) {
        System.out.println("请输入两个整数：");
        Scanner scan=new Scanner(System.in);
        int a= scan.nextInt();
        int b= scan.nextInt();
        System.out.printf("最大值为:%d",max(a,b));
        System.out.println();
        System.out.println("请输入三个小数");
        double c= scan.nextDouble();
        double d= scan.nextDouble();
        double e= scan.nextDouble();
        System.out.printf("最大值为：%f",max(c,d,e));
    }
    public static int max(int a,int b){
        return a>b?a:b;
    }
    public static double max(double c,double d,double e){
        return (c>d?c:d)>e?(c>d?c:d):e;
    }
}
